set terminal epslatex color standalone lw 1
set output"M_vir_cmc_temp.tex"
set label 1 "CMC" at graph 0.1,0.9
set key left at graph 0.02,0.2
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'cmc.dat' using 9:10 via a,p
yequal(x)=x
set ylabel offset 3,0
set key box
set key width -5
set key height 0.4
set xrange [1:150]
set yrange [10:450]
set logscale xy
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel '$M_{vir}\ (M_\odot)$'
plot"cmc.dat" using 9:10 w p pt 19 title "Data" , power(x) with line lt 1 lw 2  title \
"Power Law Fitting",\
yequal(x) with line lt 4 lw 4 title '$M_{LTE}=M_{vir}$'
set output
set terminal wxt enhanced


###################################################


set terminal epslatex color standalone lw 1
set output"M_J_cmc.tex"
set label 1 "CMC" at graph 0.1,0.9
set key right at graph 0.98,0.2
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'cmc.dat' using 9:11 via a,p
yequal(x)=x
set ylabel offset 3,0
set key box
set key width -5
set key height 0.4
set xrange [1:150]
set yrange [1:500]
set logscale xy
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel '$M_{J}\ (M_\odot)$'
plot"cmc.dat" using 9:11 w p pt 19 title "Data" , power(x) with line lt 1 lw 2  title \
"Power Law Fitting",\
yequal(x) with line lt 4 lw 4 title '$M_{LTE}=M_{J}$'
set output
set terminal wxt enhanced


###################################################

set terminal epslatex color standalone lw 1
set output"M_vir_tmc_temp.tex"
set label 1 "TMC" at graph 0.1,0.9
set key left at graph 0.02,0.2
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'tmc.dat' using 9:10 via a,p
yequal(x)=x
set ylabel offset 3,0
set key box
set key width -5
set key height 0.4
set xrange [0.01:20]
set yrange [1:200]
set logscale xy
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel '$M_{vir}\ (M_\odot)$'
plot"tmc.dat" using 9:10 w p pt 19 title "Data" , power(x) with line lt 1 lw 2  title \
"Power Law Fitting",\
yequal(x) with line lt 4 lw 4 title '$M_{LTE}=M_{vir}$'
set output
set terminal wxt enhanced


###################################################


set terminal epslatex color standalone lw 1
set output"M_J_tmc.tex"
set label 1 "TMC" at graph 0.1,0.9
set key left at graph 0.02,0.2
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'tmc.dat' using 9:11 via a,p
yequal(x)=x
set ylabel offset 3,0
set key box
set key width -5
set key height 0.4
set xrange [0.01:20]
set yrange [1:100]
set logscale xy
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel '$M_{J}\ (M_\odot)$'
plot"tmc.dat" using 9:11 w p pt 19 title "Data" , power(x) with line lt 1 lw 2  title \
"Power Law Fitting",\
yequal(x) with line lt 4 lw 4 title '$M_{LTE}=M_{J}$'
set output
set terminal wxt enhanced


cmf


set terminal epslatex color standalone lw 1
set output"cmf_tmc.tex"
set label 1 "TMC" at graph 0.1,0.9
set key right at graph 0.98,0.85
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'cmf_tmc.dat' using 1:($3/0.5) via a,p
yequal(x)=x
set ylabel offset 1,0
set key box
set key width 0
set key height 0.4
set xrange [0:5]
set yrange [-2:25]
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel 'd$M$/d$N$'
plot"cmf_tmc.dat" using 1:($3/0.5):2 w xerrorbars lt 3 lw 2 pt 7 title "Data", power(x) with line lt 1 lw 1.5  title "Power Law Fitting"
set output
set terminal wxt enhanced


set style fill solid 0.5
set terminal epslatex color standalone lw 1
set output"cmf_cmc.tex"
set label 1 "CMC" at graph 0.1,0.9
set key right at graph 0.98,0.85
power(x)=a*(x**p)    
fit [0.05:150] power(x) 'cmf_cmc.dat' using 1:($3/10) via a,p
yequal(x)=x
set ylabel offset 1,0
set key box
set key width 0
set key height 0.4
set xrange [0:70]
set yrange [-0.01:0.7]
set xlabel '$M_{LTE}\ (M_\odot)$'
set ylabel 'd$M$/d$N$'
plot"cmf_cmc.dat" using 1:($3/10):2 w xerrorbars lt 3 lw 2 pt 7 title "Data", power(x) with line lt 1 lw 1.5  title "Power Law Fitting"
set output
set terminal wxt enhanced